package com.normal.main.fragment

import android.os.Bundle
import android.util.Log
import android.view.View
import androidx.navigation.fragment.findNavController
import com.normal.main.R
import com.normal.main.databinding.FragmentOrderBinding
import com.normal.zbase.impl.base.BaseFragment
import com.normal.zbase.impl.tools.extend.logger
import com.normal.zbase.impl.tools.extend.popBackStack
import com.normal.zbase.impl.tools.extend.viewBinding

/**
 * Created by zsf on 2021/1/4 13:59
 * ******************************************
 * *
 * ******************************************
 */
class OrderFragment : BaseFragment<FragmentOrderBinding>() {
    override fun viewBinding(): FragmentOrderBinding {
        return FragmentOrderBinding.inflate(layoutInflater)
    }

    override fun initView(view: View, savedInstanceState: Bundle?) {
        super.initView(view, savedInstanceState)
        val userId = arguments?.getString("userId")
        logger.info(userId)

        with(viewBinding) {
            btnHome.setOnClickListener {
                findNavController().navigate(
                    R.id.action_orderFragment_to_homeFragment
                )
            }
            btnFirst.setOnClickListener {
                findNavController().popBackStack()
            }
        }

    }


}